<?php
    include 'base.php';
    $username = $_POST['username']; 
    $password = $_POST['password'];
    // $username = "15909831756"; 
    // $password = "15909831756";
    // $sql = "INSERT INTO `user` (`username`, `password`) VALUES ('$username', '$password')";
    $sql = "INSERT INTO `user` (`username`, `password`, `Focusonhousing`,`Focus_secondHands`,`Focus_lease`) VALUES ('$username', '$password', ' ',' ',' ')";
    $res = $conn->query($sql);
    if (json_encode($res) == 'false') {
         echo json_encode(array(
            "msg" => '该手机号已被注册',
            "bcolor" => 'rgba(196, 54, 19, 0.5)',
        ));
    }else{
         echo json_encode(array(
            "msg" => '注册成功,如果登录请点击立即登录',
            "bcolor" => 'rgba(25, 179, 56, 0.5)',
        ));
    }
?>  
